<%@ Page Title="" Language="C#" MasterPageFile="~/Views/Shared/Site.Master" Inherits="MvcContrib.FluentHtml.ModelViewPage<Universum.Model.Domain.Blogs.Blog>" %>

<asp:Content ID="Content1" ContentPlaceHolderID="TitleContent" runat="server">
	Universum - Blog details
</asp:Content>
<asp:Content ID="BreadcrumbsContent" ContentPlaceHolderID="Breadcrumbs" runat ="server">
<%= Html.Breadcrumb().Home().Append<BlogsController>(c=>c.Index(), "Posts from "+ ( Model.Owner?? "blog")).AppendText("Blog details").End() %>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">
	<h2>This is <%=Model.Owner %>'s blog called `<%= Html.Encode(Model.Name) %>`</h2>
	
		<p>
		View 
		<% Html.BeginLinkWithUsername<BlogsController>(it => it.Index(), Model.Owner); %>
		all of this blog's posts
		<% Html.EndLink(); %>
		 or view it's description below.
		</p>
		<p>			
			<%=Model.Description %>
		</p>
		<% if (Html.LoggedInUser().Identity.Name == Model.Owner)
	 { %>
		<p>
		<%=Html.ActionLink<BlogsController>(controller => controller.Edit(), "Edit"/*, new {  id=Model.PrimaryKey }*/ )%>
		<%} %>
		</p>
	
	
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="ScriptPlaceHolder" runat="server">
</asp:Content>
